<%@page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>个人信息</title>
<%@ include file="/common/header/meta.jsp"%>
<%@ include file="/common/header/script.jsp"%>
<script type="text/javascript">
	$(function() {
		tabsContainer = $("#tabsContainer").tabs({
			fit: true, border: false, tabPosition: 'bottom'
		}) ;
		
		
		$.ajax({
            url: base.contextPath+"/sysmgr/user/doNotNeedAuth_MyAccountInfo.do", 
            type: "get", dataType: "json", data: {id: base.user_id},
            beforeSend: function (XMLHttpRequest) { $.easyui.loading({ msg: "数据添加中，请稍等..."}); },
            success: function (result, textStatus, XMLHttpRequest) {
            	if (result.status) {
    				$("span[name=num]").append(result.obj.user.num) ;
    				$("span[name=account]").append(result.obj.user.account) ;
    				$("span[name=status]").append((result.obj.user.status==0?"正常":"锁定")) ;
    				$("span[name=truename]").append(result.obj.user.truename) ;
    				$("span[name=email]").append(result.obj.user.email) ;
    				
    				if(result.obj.userroles) {
    					$.each(result.obj.userroles, function(i, p){
    						$("span[name=userroles]").append(p.name+(i==3?"<br/>":"----")) ;
    					});
    				} else {
    					$("span[name=userroles]").append("无") ;
    				}
    				if(result.obj.workgroups) {
    					$.each(result.obj.workgroups, function(i, p){
    						$("span[name=workgroups]").append(p.name+(i==3?"<br/>":"----")) ;
    					});
    				} else {
    					$("span[name=workgroups]").append("无") ;
    				}
    				if(result.obj.permits) {
    					$.each(result.obj.permits, function(i, p){
    						$("span[name=permits]").append(p.name+(i==3?"<br/>":"----")) ;
    					});
    				} else {
    					$("span[name=permits]").append("无") ;
    				}
    			}
            },
            complete: function (XMLHttpRequest, textStatus) {$.easyui.loaded();},
            error: function() {$.easyui.loaded();}
        });
		
	});
</script>
</head>

<body>
	<div id="tabsContainer">
		<div class="panel-container" data-options="title: '个人信息', iconCls: 'icon-standard-layout-header', refreshable: false, selected: true">
			<div class="form_container">
				
				<table class="tableform">
					<tr>
						<th style="width:100px;text-align: left;">个人信息</th> 
						<td colspan="6" style="border:0px;"></td>
					</tr>
					<tr>
						<th style="width:100px;">姓　　名：</th>
						<td style="width:30%;"><span name="truename"></span></td>
						<th style="width:100px;">员工编号：</th>
						<td style="width:30%;"><span name="num"></span></td>
						<td rowspan="7" style="width:170px;" valign="top">
							<p style="width:110px;height:150px;border:1px solid #ccc;margin:5px auto;"></p>
							<p style="margin:0 auto ;text-align: center;">
								<a onClick="" class="easyui-linkbutton" data-options="plain: true, iconCls: 'ext_add'">选择照片</a>
							</p>
						</td>
					</tr>
					<tr>
						<th>用户帐号：</th>
						<td><span name="account"></span></td>
						<th>账号状态：</th>
						<td><span name="status"></span></td>
					</tr>
					<tr>
						<th>隶属部门：</th>
						<td></td>
						<th>籍　　贯：</th>
						<td></td>
					</tr>
					<tr>
						<th>工资卡号：</th>
						<td></td>
						<th>社&nbsp;&nbsp;保&nbsp;&nbsp;号：</th>
						<td></td>
					</tr>
					<tr>
						<th>曾&nbsp;&nbsp;用&nbsp;&nbsp;名：</th>
						<td></td>
						<th>性　　别：</th>
						<td></td>
					</tr>
					<tr>
						<th>出生日期：</th>
						<td></td>
						<th>年　　龄：</th>
						<td></td>
					</tr>
					<tr>
						<th>出&nbsp;&nbsp;生&nbsp;&nbsp;地：</th>
						<td></td>
						<th>民　　族：</th>
						<td></td>
					</tr>
					<tr>
						<th>户　　口：</th>
						<td></td>
						<th>户口性质：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>婚姻状况：</th>
						<td></td>
						<th>员工身份：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>国　　籍：</th>
						<td></td>
						<th>证件类型：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>政治面貌：</th>
						<td></td>
						<th>健康状况：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>身　　高：</th>
						<td></td>
						<th>体　　重：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>视　　力：</th>
						<td></td>
						<th>最高学历：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>最高学位：</th>
						<td></td>
						<th>专　　业：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>职　　称：</th>
						<td></td>
						<th>毕业院校：</th>
						<td colspan="2"></td>
					</tr> 
					<tr>
						<th>参加工作日期：</th>
						<td></td>
						<th>空闲工龄：</th>
						<td colspan="2"></td>
					</tr>
					<tr>
						<th>创 建 人：</th>
						<td></td>
						<th>创建时间：</th>
						<td colspan="2"></td>
					</tr>
				</table>
					
			</div>
		</div>
		
		<div class="panel-container" data-options="title: '其他信息', iconCls: 'icon-standard-layout-header', refreshable: false, selected: true">
		</div>
		
	</div>
</body>
</html>